package com.hn.shopapi.controller;

import com.alibaba.dubbo.config.annotation.Reference;
import com.hn.shopdubbo.dubbo.service.DubboService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/dubbo")
public class DubboController {
    @Reference //注意这个是 com.alibaba.dubbo.config.annotation.Reference;包下的
    DubboService dubboService;

    @GetMapping("/test")
    public String test(String str){
        return dubboService.test(str);
    }

}
